package com.wind.taobao.api.trade.shop.rest
{
	import com.wind.taobao.api.trade.shop.convert.ShopConvert;
	import com.wind.taobao.api.trade.shop.model.TaobaoShop;
	import com.wind.taobao.core.webservice.TaobaoResponse;

	/**
	 * taobao.shop.get Response
	 * @author fxy
	 *
	 */
	public class ShopGetResponse extends TaobaoResponse
	{
		public var shop:TaobaoShop;

		public function ShopGetResponse(response:TaobaoResponse=null)
		{
			super(response);
			initShop();
		}

		private function initShop():void
		{
			if (body != null && this.isSuccess)
			{
				if (body["rsp"].hasOwnProperty("shops"))
					shop=ShopConvert.convertShop(body["rsp"]["shops"][0]);
			}
		}

	}
}